import request from '@/utils/request'

export function getSecurityLevels() {
  return request({
    url: '/api/files/levels',
    method: 'get'
  })
}

// 删除文件
export function deleteFile(fileId) {
  return request({
    url: '/api/files/' + fileId,
    method: 'delete'
  })
}

// 文件重命名
export function renameFile(data) {
  return request({
    url: `/api/files/${data.fileId}/renameFile`,
    method: 'put',
    data: { newName: data.newName }
  })
}